/*
 * $Id: field.h,v 1.81.6.3 Broadcom SDK $
 * 
 * $Copyright: Copyright 2011 Broadcom Corporation.
 * This program is the proprietary software of Broadcom Corporation
 * and/or its licensors, and may only be used, duplicated, modified
 * or distributed pursuant to the terms and conditions of a separate,
 * written license agreement executed between you and Broadcom
 * (an "Authorized License").  Except as set forth in an Authorized
 * License, Broadcom grants no license (express or implied), right
 * to use, or waiver of any kind with respect to the Software, and
 * Broadcom expressly reserves all rights in and to the Software
 * and all intellectual property rights therein.  IF YOU HAVE
 * NO AUTHORIZED LICENSE, THEN YOU HAVE NO RIGHT TO USE THIS SOFTWARE
 * IN ANY WAY, AND SHOULD IMMEDIATELY NOTIFY BROADCOM AND DISCONTINUE
 * ALL USE OF THE SOFTWARE.  
 *  
 * Except as expressly set forth in the Authorized License,
 *  
 * 1.     This program, including its structure, sequence and organization,
 * constitutes the valuable trade secrets of Broadcom, and you shall use
 * all reasonable efforts to protect the confidentiality thereof,
 * and to use this information only in connection with your use of
 * Broadcom integrated circuit products.
 *  
 * 2.     TO THE MAXIMUM EXTENT PERMITTED BY LAW, THE SOFTWARE IS
 * PROVIDED "AS IS" AND WITH ALL FAULTS AND BROADCOM MAKES NO PROMISES,
 * REPRESENTATIONS OR WARRANTIES, EITHER EXPRESS, IMPLIED, STATUTORY,
 * OR OTHERWISE, WITH RESPECT TO THE SOFTWARE.  BROADCOM SPECIFICALLY
 * DISCLAIMS ANY AND ALL IMPLIED WARRANTIES OF TITLE, MERCHANTABILITY,
 * NONINFRINGEMENT, FITNESS FOR A PARTICULAR PURPOSE, LACK OF VIRUSES,
 * ACCURACY OR COMPLETENESS, QUIET ENJOYMENT, QUIET POSSESSION OR
 * CORRESPONDENCE TO DESCRIPTION. YOU ASSUME THE ENTIRE RISK ARISING
 * OUT OF USE OR PERFORMANCE OF THE SOFTWARE.
 * 
 * 3.     TO THE MAXIMUM EXTENT PERMITTED BY LAW, IN NO EVENT SHALL
 * BROADCOM OR ITS LICENSORS BE LIABLE FOR (i) CONSEQUENTIAL,
 * INCIDENTAL, SPECIAL, INDIRECT, OR EXEMPLARY DAMAGES WHATSOEVER
 * ARISING OUT OF OR IN ANY WAY RELATING TO YOUR USE OF OR INABILITY
 * TO USE THE SOFTWARE EVEN IF BROADCOM HAS BEEN ADVISED OF THE
 * POSSIBILITY OF SUCH DAMAGES; OR (ii) ANY AMOUNT IN EXCESS OF
 * THE AMOUNT ACTUALLY PAID FOR THE SOFTWARE ITSELF OR USD 1.00,
 * WHICHEVER IS GREATER. THESE LIMITATIONS SHALL APPLY NOTWITHSTANDING
 * ANY FAILURE OF ESSENTIAL PURPOSE OF ANY LIMITED REMEDY.$
 * 
 * DO NOT EDIT THIS FILE!
 * This file is auto-generated.
 * Edits to this file will be lost when it is regenerated.
 */

#ifndef __BCMX_FIELD_H__
#define __BCMX_FIELD_H__

#include <bcm/types.h>
#include <bcmx/bcmx.h>
#include <bcmx/lplist.h>
#include <bcm/field.h>
#include <bcmx/policer.h>

/* DATA qualifier object, used for creation of custom data qualifiers. */
typedef bcm_field_data_qualifier_t bcmx_field_data_qualifier_t;

/* Ethertype based DATA packet qualifier structure. */
typedef bcm_field_data_ethertype_t bcmx_field_data_ethertype_t;

/* Ip protocol/Next header based DATA packet qualifier structure. */
typedef bcm_field_data_ip_protocol_t bcmx_field_data_ip_protocol_t;

/* Packet format based DATA qualifier specification structure. */
typedef bcm_field_data_packet_format_t bcmx_field_data_packet_format_t;

/* Initialize Field Data Qualifier structure. */
extern void bcmx_field_data_qualifier_t_init(
    bcmx_field_data_qualifier_t *data_qual);

/* Initialize ethertype based field data qualifier. */
extern void bcmx_field_data_ethertype_t_init(
    bcmx_field_data_ethertype_t *etype);

/* Initialize ip protocol based field data qualifier. */
extern void bcmx_field_data_ip_protocol_t_init(
    bcmx_field_data_ip_protocol_t *ip_protocol);

/* Initialize packet format based field data qualifier. */
extern void bcmx_field_data_packet_format_t_init(
    bcmx_field_data_packet_format_t *packet_format);

/* Initialize field software subsystem. */
extern int bcmx_field_init(void);

/* Get a field control value. */
extern int bcmx_field_control_get(
    bcm_field_control_t control, 
    uint32 *state);

/* Set a field control value. */
extern int bcmx_field_control_set(
    bcm_field_control_t control, 
    uint32 state);

/* 
 * Traverse all the fp groups in the system, calling a specified callback
 * for each one
 */
extern int bcmx_field_group_traverse(
    bcm_field_group_traverse_cb callback, 
    void *user_data);

/* Create a field group. */
extern int bcmx_field_group_create(
    bcm_field_qset_t qset, 
    int pri, 
    bcm_field_group_t *group);

/* Create a field group. */
extern int bcmx_field_group_create_id(
    bcm_field_qset_t qset, 
    int pri, 
    bcm_field_group_t group);

/* Create a field group. */
extern int bcmx_field_group_create_mode(
    bcm_field_qset_t qset, 
    int pri, 
    bcm_field_group_mode_t mode, 
    bcm_field_group_t *group);

/* Create a field group. */
extern int bcmx_field_group_create_mode_id(
    bcm_field_qset_t qset, 
    int pri, 
    bcm_field_group_mode_t mode, 
    bcm_field_group_t group);

/* Create a field group. */
extern int bcmx_field_group_port_create_mode(
    bcmx_lport_t port, 
    bcm_field_qset_t qset, 
    int pri, 
    bcm_field_group_mode_t mode, 
    bcm_field_group_t *group);

/* Create a field group. */
extern int bcmx_field_group_port_create_mode_id(
    bcmx_lport_t port, 
    bcm_field_qset_t qset, 
    int pri, 
    bcm_field_group_mode_t mode, 
    bcm_field_group_t group);

/* Create a field group. */
extern int bcmx_field_group_ports_create_mode(
    bcmx_lplist_t lplist, 
    bcm_field_qset_t qset, 
    int pri, 
    bcm_field_group_mode_t mode, 
    bcm_field_group_t *group);

/* Create a field group. */
extern int bcmx_field_group_ports_create_mode_id(
    bcmx_lplist_t lplist, 
    bcm_field_qset_t qset, 
    int pri, 
    bcm_field_group_mode_t mode, 
    bcm_field_group_t group);

/* Create a wlan field group. */
extern int bcmx_field_group_wlan_create_mode(
    bcm_field_qset_t qset, 
    int pri, 
    bcm_field_group_mode_t mode, 
    bcm_field_group_t *group);

/* Create a wlan field group. */
extern int bcmx_field_group_wlan_create_mode_id(
    bcm_field_qset_t qset, 
    int pri, 
    bcm_field_group_mode_t mode, 
    bcm_field_group_t group);

/* Get the mode of a group. */
extern int bcmx_field_group_mode_get(
    bcm_field_group_t group, 
    bcm_field_group_mode_t *mode);

/* Change or retrieve the qualifiers for a field group. */
extern int bcmx_field_group_set(
    bcm_field_group_t group, 
    bcm_field_qset_t qset);

/* Change or retrieve the qualifiers for a field group. */
extern int bcmx_field_group_get(
    bcm_field_group_t group, 
    bcm_field_qset_t *qset);

/* Deallocates a field group. */
extern int bcmx_field_group_destroy(
    bcm_field_group_t group);

/* Compress field group entries. */
extern int bcmx_field_group_compress(
    bcm_field_group_t group);

/* Set field group priority. */
extern int bcmx_field_group_priority_set(
    bcm_field_group_t group, 
    int priority);

/* Get field group priority. */
extern int bcmx_field_group_priority_get(
    bcm_field_group_t group, 
    int *priority);

/* Set the group enable state. */
extern int bcmx_field_group_enable_set(
    bcm_field_group_t group, 
    int enable);

/* Get the group enable state. */
extern int bcmx_field_group_enable_get(
    bcm_field_group_t group, 
    int *enable);

/* Allocate a range checker with specified configuration. */
extern int bcmx_field_range_create(
    bcm_field_range_t *range, 
    uint32 flags, 
    bcm_l4_port_t min, 
    bcm_l4_port_t max);

/* 
 * Install all entries of a field group into the hardware tables (will
 * silently reinstall entries already in the hardware tables)
 */
extern int bcmx_field_group_install(
    bcm_field_group_t group);

/* 
 * Remove all entries of a field group from the hardware tables (will
 * silently ignore entries not in the hardware tables)
 */
extern int bcmx_field_group_remove(
    bcm_field_group_t group);

/* Allocate a range checker with specified configuration. */
extern int bcmx_field_range_create_id(
    bcm_field_range_t range, 
    uint32 flags, 
    bcm_l4_port_t min, 
    bcm_l4_port_t max);

/* 
 * Allocate a range checker with specified configuration associated with
 * an interface group.
 */
extern int bcmx_field_range_group_create(
    bcm_field_range_t *range, 
    uint32 flags, 
    bcm_l4_port_t min, 
    bcm_l4_port_t max, 
    bcm_if_group_t group);

/* 
 * Allocate a range checker with specified configuration associated with
 * an interface group.
 */
extern int bcmx_field_range_group_create_id(
    bcm_field_range_t range, 
    uint32 flags, 
    bcm_l4_port_t min, 
    bcm_l4_port_t max, 
    bcm_if_group_t group);

/* Retrieve parameters associated with an existing range checker. */
extern int bcmx_field_range_get(
    bcm_field_range_t range, 
    uint32 *flags, 
    bcm_l4_port_t *min, 
    bcm_l4_port_t *max);

/* Destroy a virtual range checker. */
extern int bcmx_field_range_destroy(
    bcm_field_range_t range);

/* Create an data/offset based qualifier. */
extern int bcmx_field_data_qualifier_create(
    bcmx_field_data_qualifier_t *data_qualifier);

/* Return list of ids of defined data qualifiers. */
extern int bcmx_field_data_qualifier_multi_get(
    int qual_size, 
    int *qual_array, 
    int *qual_count);

/* Return configuration of given data qualifier. */
extern int bcmx_field_data_qualifier_get(
    int qual_id, 
    bcmx_field_data_qualifier_t *qual);

/* Destroy an data/offset based qualifier. */
extern int bcmx_field_data_qualifier_destroy(
    int qual_id);

/* Delete all data/offset based qualifiers. */
extern int bcmx_field_data_qualifier_destroy_all(void);

/* Add ethertype based offset to data qualifier object. */
extern int bcmx_field_data_qualifier_ethertype_add(
    int qual_id, 
    bcmx_field_data_ethertype_t *etype);

/* Remove ethertype based offset from data qualifier object. */
extern int bcmx_field_data_qualifier_ethertype_delete(
    int qual_id, 
    bcmx_field_data_ethertype_t *etype);

/* Add ip protocol based offset to data qualifier object. */
extern int bcmx_field_data_qualifier_ip_protocol_add(
    int qual_id, 
    bcmx_field_data_ip_protocol_t *ip_protocol);

/* Remove ip protocol based offset from data qualifier object. */
extern int bcmx_field_data_qualifier_ip_protocol_delete(
    int qual_id, 
    bcmx_field_data_ip_protocol_t *ip_protocol);

/* Add packet format based offset/s to data qualifier object. */
extern int bcmx_field_data_qualifier_packet_format_add(
    int qual_id, 
    bcmx_field_data_packet_format_t *packet_format);

/* Remove packet format based offset/s from data qualifier object. */
extern int bcmx_field_data_qualifier_packet_format_delete(
    int qual_id, 
    bcmx_field_data_packet_format_t *packet_format);

/* Add field data qualifier to group qset. */
extern int bcmx_field_qset_data_qualifier_add(
    bcm_field_qset_t *qset, 
    int qual_id);

/* Get field data qualifiers included in group qset. */
extern int bcmx_field_qset_data_qualifier_get(
    bcm_field_qset_t *qset, 
    int qual_max, 
    int *qual_arr, 
    int *qual_count);

/* 
 * Set user-defined field information (location within packet of
 * particular format).
 */
extern int bcmx_field_udf_spec_set(
    bcm_field_udf_spec_t *udf_spec, 
    uint32 flags, 
    uint32 offset);

/* 
 * Get user-defined field information (location within packet of
 * particular format).
 */
extern int bcmx_field_udf_spec_get(
    bcm_field_udf_spec_t *udf_spec, 
    uint32 *flags, 
    uint32 *offset);

/* Create (install) and query a virtual UDF resource. */
extern int bcmx_field_udf_create(
    bcm_field_udf_spec_t *udf_spec, 
    bcm_field_udf_t *udf_id);

/* Create (install) and query a virtual UDF resource. */
extern int bcmx_field_udf_create_id(
    bcm_field_udf_spec_t *udf_spec, 
    bcm_field_udf_t udf_id);

/* Set the UDF Ethertype match value. */
extern int bcmx_field_udf_ethertype_set(
    int index, 
    bcm_port_frametype_t frametype, 
    bcm_port_ethertype_t ethertype);

/* Get the UDF Ethertype match value. */
extern int bcmx_field_udf_ethertype_get(
    int index, 
    bcm_port_frametype_t *frametype, 
    bcm_port_ethertype_t *ethertype);

/* Set the UDF IP Protocol match values. */
extern int bcmx_field_udf_ipprotocol_set(
    int index, 
    uint32 flags, 
    uint8 proto);

/* Get the UDF IP Protocol match values. */
extern int bcmx_field_udf_ipprotocol_get(
    int index, 
    uint32 *flags, 
    uint8 *proto);

/* Create (install) and query a virtual UDF resource. */
extern int bcmx_field_udf_get(
    bcm_field_udf_spec_t *udf_spec, 
    bcm_field_udf_t udf_id);

/* Destroy a virtual UDF resource. */
extern int bcmx_field_udf_destroy(
    bcm_field_udf_t udf_id);

/* Add a virtual UDF resource to a qset (for subsequent group creation). */
extern int bcmx_field_qset_add_udf(
    bcm_field_qset_t *qset, 
    bcm_field_udf_t udf_id);

/* Get array of virtual UDF resources included in group qset. */
extern int bcmx_field_qset_udf_get(
    bcm_field_qset_t *qset, 
    int udf_max, 
    int *udf_arr, 
    int *udf_count);

/* Create a blank field entry. */
extern int bcmx_field_entry_create(
    bcm_field_group_t group, 
    bcm_field_entry_t *entry);

/* Create a blank field entry. */
extern int bcmx_field_entry_create_id(
    bcm_field_group_t group, 
    bcm_field_entry_t entry);

/* Get field entries. */
extern int bcmx_field_entry_multi_get(
    bcm_field_group_t group, 
    int entry_size, 
    bcm_field_entry_t *entry_array, 
    int *entry_count);

/* Destroy a field entry. */
extern int bcmx_field_entry_destroy(
    bcm_field_entry_t entry);

/* Destroy all field entries. */
extern int bcmx_field_entry_destroy_all(void);

/* Create a copy of an existing field entry. */
extern int bcmx_field_entry_copy(
    bcm_field_entry_t src_entry, 
    bcm_field_entry_t *dst_entry);

/* Install a field entry into the hardware tables. */
extern int bcmx_field_entry_install(
    bcm_field_entry_t entry);

/* Re-install a field entry into the hardware tables. */
extern int bcmx_field_entry_reinstall(
    bcm_field_entry_t entry);

/* Remove a field entry from the hardware tables. */
extern int bcmx_field_entry_remove(
    bcm_field_entry_t entry);

/* Attach a policer to a field entry. */
extern int bcmx_field_entry_policer_attach(
    bcm_field_entry_t entry_id, 
    int level, 
    bcm_policer_t policer_id);

/* Detach a policer from a field entry. */
extern int bcmx_field_entry_policer_detach(
    bcm_field_entry_t entry_id, 
    int level);

/* Detach all policers from a field entry. */
extern int bcmx_field_entry_policer_detach_all(
    bcm_field_entry_t entry_id);

/* Get the policer(s) attached to a field entry. */
extern int bcmx_field_entry_policer_get(
    bcm_field_entry_t entry_id, 
    int level, 
    bcm_policer_t *policer_id);

/* Get/Set the priority for an entry within a group. */
extern int bcmx_field_entry_prio_get(
    bcm_field_entry_t entry, 
    int *prio);

/* Get/Set the priority for an entry within a group. */
extern int bcmx_field_entry_prio_set(
    bcm_field_entry_t entry, 
    int prio);

/* Invalidate HW FP entries that have not been replayed after warm boot. */
extern int bcmx_field_resync(void);

/* Remove all qualifications from a field entry. */
extern int bcmx_field_qualify_clear(
    bcm_field_entry_t entry);

/* Add data field that the packet must match to trigger qualifier. */
extern int bcmx_field_qualify_data(
    bcm_field_entry_t eid, 
    int qual_id, 
    uint8 *data, 
    uint8 *mask, 
    uint16 length);

/* Remove match criteria from a field processor entry. */
extern int bcmx_field_qualifier_delete(
    bcm_field_entry_t entry, 
    bcm_field_qualify_t qual_id);

extern int bcmx_field_qualify_InPort(
    bcm_field_entry_t entry, 
    bcmx_lport_t port);

extern int bcmx_field_qualify_OutPort(
    bcm_field_entry_t entry, 
    bcmx_lport_t port);

extern int bcmx_field_qualify_InPorts(
    bcm_field_entry_t entry, 
    bcmx_lplist_t lplist);

extern int bcmx_field_qualify_OutPorts(
    bcm_field_entry_t entry, 
    bcmx_lplist_t lplist);

extern int bcmx_field_qualify_Drop(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_SrcModid(
    bcm_field_entry_t entry, 
    bcm_module_t data, 
    bcm_module_t mask);

extern int bcmx_field_qualify_SrcPort(
    bcm_field_entry_t entry, 
    bcmx_lport_t port);

extern int bcmx_field_qualify_SrcTrunk(
    bcm_field_entry_t entry, 
    bcm_trunk_t tid);

extern int bcmx_field_qualify_DstModid(
    bcm_field_entry_t entry, 
    bcm_module_t data, 
    bcm_module_t mask);

extern int bcmx_field_qualify_DstPort(
    bcm_field_entry_t entry, 
    bcmx_lport_t port);

extern int bcmx_field_qualify_DstTrunk(
    bcm_field_entry_t entry, 
    bcm_trunk_t tid);

extern int bcmx_field_qualify_InnerL4SrcPort(
    bcm_field_entry_t entry, 
    bcm_l4_port_t data, 
    bcm_l4_port_t mask);

extern int bcmx_field_qualify_InnerL4DstPort(
    bcm_field_entry_t entry, 
    bcm_l4_port_t data, 
    bcm_l4_port_t mask);

extern int bcmx_field_qualify_L4SrcPort(
    bcm_field_entry_t entry, 
    bcm_l4_port_t data, 
    bcm_l4_port_t mask);

extern int bcmx_field_qualify_L4DstPort(
    bcm_field_entry_t entry, 
    bcm_l4_port_t data, 
    bcm_l4_port_t mask);

extern int bcmx_field_qualify_OuterVlan(
    bcm_field_entry_t entry, 
    bcm_vlan_t data, 
    bcm_vlan_t mask);

/* 
 *  Set match criteria for bcmFieldQualifyOuterVlanId
 *                  qualifier in the field entry.
 */
extern int bcmx_field_qualify_OuterVlanId(
    bcm_field_entry_t entry, 
    bcm_vlan_t data, 
    bcm_vlan_t mask);

/* 
 *  Set match criteria for bcmFieldQualifyOuterVlanPri
 *                  qualifier in the field entry.
 */
extern int bcmx_field_qualify_OuterVlanPri(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

/* 
 *  Set match criteria for bcmFieldQualifyOuterVlanCfi
 *                  qualifier in the field entry.
 */
extern int bcmx_field_qualify_OuterVlanCfi(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_InnerVlan(
    bcm_field_entry_t entry, 
    bcm_vlan_t data, 
    bcm_vlan_t mask);

/* 
 *  Set match criteria for bcmFieldQualifyInnerVlanId
 *                  qualifier in the field entry.
 */
extern int bcmx_field_qualify_InnerVlanId(
    bcm_field_entry_t entry, 
    bcm_vlan_t data, 
    bcm_vlan_t mask);

/* 
 *  Set match criteria for bcmFieldQualifyInnerVlanPri
 *                  qualifier in the field entry.
 */
extern int bcmx_field_qualify_InnerVlanPri(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

/* 
 *  Set match criteria for bcmFieldQualifyInnerVlanCfi
 *                  qualifier in the field entry.
 */
extern int bcmx_field_qualify_InnerVlanCfi(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_EtherType(
    bcm_field_entry_t entry, 
    uint16 data, 
    uint16 mask);

extern int bcmx_field_qualify_EqualL4Port(
    bcm_field_entry_t entry, 
    uint32 flag);

/* Add loopback field qualification to a field entry. */
extern int bcmx_field_qualify_Loopback(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

/* Add loopback type field qualification to a field entry. */
extern int bcmx_field_qualify_LoopbackType(
    bcm_field_entry_t entry, 
    bcm_field_LoopbackType_t loopback_type);

/* Add tunnel type field qualification to a field entry. */
extern int bcmx_field_qualify_TunnelType(
    bcm_field_entry_t entry, 
    bcm_field_TunnelType_t tunnel_type);

extern int bcmx_field_qualify_DstL3Egress(
    bcm_field_entry_t entry, 
    bcm_if_t if_id);

extern int bcmx_field_qualify_DstMulticastGroup(
    bcm_field_entry_t entry, 
    bcm_gport_t group);

extern int bcmx_field_qualify_SrcMplsGport(
    bcm_field_entry_t entry, 
    bcm_gport_t mpls_port_id);

extern int bcmx_field_qualify_DstMplsGport(
    bcm_field_entry_t entry, 
    bcm_gport_t mpls_port_id);

extern int bcmx_field_qualify_SrcMimGport(
    bcm_field_entry_t entry, 
    bcm_gport_t mim_port_id);

extern int bcmx_field_qualify_DstMimGport(
    bcm_field_entry_t entry, 
    bcm_gport_t mim_port_id);

extern int bcmx_field_qualify_SrcWlanGport(
    bcm_field_entry_t entry, 
    bcm_gport_t wlan_port_id);

extern int bcmx_field_qualify_DstWlanGport(
    bcm_field_entry_t entry, 
    bcm_gport_t wlan_port_id);

/* 
 * Set match criteria for bcmFieldQualifyIntPriority
 *                qualifier in the field entry.
 */
extern int bcmx_field_qualify_IntPriority(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

/* 
 * Set match criteria for bcmFieldQualifyForwardingVlanId
 *                qualifier in the field entry.
 */
extern int bcmx_field_qualify_ForwardingVlanId(
    bcm_field_entry_t entry, 
    bcm_vlan_t data, 
    bcm_vlan_t mask);

/* 
 * Get match criteria for bcmFieldQualifyForwardingVlanId
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_ForwardingVlanId_get(
    bcm_field_entry_t entry, 
    bcm_vlan_t *data, 
    bcm_vlan_t *mask);

/* 
 * Set match criteria for bcmFieldQualifyVpn
 *                qualifier in the field entry.
 */
extern int bcmx_field_qualify_Vpn(
    bcm_field_entry_t entry, 
    bcm_vpn_t data, 
    bcm_vpn_t mask);

/* 
 * Get match criteria for bcmFieldQualifyVpn
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_Vpn_get(
    bcm_field_entry_t entry, 
    bcm_vpn_t *data, 
    bcm_vpn_t *mask);

/* 
 * Set match criteria for bcmFieldQualifyColor
 *                qualifier in the field entry.
 */
extern int bcmx_field_qualify_Color(
    bcm_field_entry_t entry, 
    uint8 color);

/* 
 * Set match criteria for bcmFieldQualifySrcModPortGport
 *                qualifier in the field entry.
 */
extern int bcmx_field_qualify_SrcModPortGport(
    bcm_field_entry_t entry, 
    bcm_gport_t data);

/* 
 * Set match criteria for bcmFieldQualifySrcModuleGport
 *                qualifier in the field entry.
 */
extern int bcmx_field_qualify_SrcModuleGport(
    bcm_field_entry_t entry, 
    bcm_gport_t data);

extern int bcmx_field_qualify_IpProtocol(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_LookupStatus(
    bcm_field_entry_t entry, 
    uint32 data, 
    uint32 mask);

extern int bcmx_field_qualify_IpInfo(
    bcm_field_entry_t entry, 
    uint32 data, 
    uint32 mask);

extern int bcmx_field_qualify_PacketRes(
    bcm_field_entry_t entry, 
    uint32 data, 
    uint32 mask);

extern int bcmx_field_qualify_SrcIp(
    bcm_field_entry_t entry, 
    bcm_ip_t data, 
    bcm_ip_t mask);

extern int bcmx_field_qualify_DstIp(
    bcm_field_entry_t entry, 
    bcm_ip_t data, 
    bcm_ip_t mask);

extern int bcmx_field_qualify_DSCP(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_Tos(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_IpFlags(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_TcpControl(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_TcpSequenceZero(
    bcm_field_entry_t entry, 
    uint32 flag);

extern int bcmx_field_qualify_TcpHeaderSize(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_Ttl(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_RangeCheck(
    bcm_field_entry_t entry, 
    int range, 
    int result);

extern int bcmx_field_qualify_SrcIp6(
    bcm_field_entry_t entry, 
    bcm_ip6_t data, 
    bcm_ip6_t mask);

extern int bcmx_field_qualify_DstIp6(
    bcm_field_entry_t entry, 
    bcm_ip6_t data, 
    bcm_ip6_t mask);

extern int bcmx_field_qualify_SrcIp6High(
    bcm_field_entry_t entry, 
    bcm_ip6_t data, 
    bcm_ip6_t mask);

extern int bcmx_field_qualify_SrcIpEqualDstIp(
    bcm_field_entry_t entry, 
    uint32 flag);

extern int bcmx_field_qualify_DstIp6High(
    bcm_field_entry_t entry, 
    bcm_ip6_t data, 
    bcm_ip6_t mask);

extern int bcmx_field_qualify_DstIp6Low(
    bcm_field_entry_t entry, 
    bcm_ip6_t data, 
    bcm_ip6_t mask);

extern int bcmx_field_qualify_SrcIp6Low(
    bcm_field_entry_t entry, 
    bcm_ip6_t data, 
    bcm_ip6_t mask);

extern int bcmx_field_qualify_Ip6NextHeader(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_Ip6TrafficClass(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_InnerIp6FlowLabel(
    bcm_field_entry_t entry, 
    uint32 data, 
    uint32 mask);

extern int bcmx_field_qualify_Ip6FlowLabel(
    bcm_field_entry_t entry, 
    uint32 data, 
    uint32 mask);

extern int bcmx_field_qualify_Ip6HopLimit(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_SrcMac(
    bcm_field_entry_t entry, 
    bcm_mac_t data, 
    bcm_mac_t mask);

extern int bcmx_field_qualify_DstMac(
    bcm_field_entry_t entry, 
    bcm_mac_t data, 
    bcm_mac_t mask);

extern int bcmx_field_qualify_PacketFormat(
    bcm_field_entry_t entry, 
    uint32 data, 
    uint32 mask);

extern int bcmx_field_qualify_SrcMacGroup(
    bcm_field_entry_t entry, 
    uint32 data, 
    uint32 mask);

extern int bcmx_field_qualify_InnerIpType(
    bcm_field_entry_t entry, 
    bcm_field_IpType_t type);

extern int bcmx_field_qualify_ForwardingType(
    bcm_field_entry_t entry, 
    bcm_field_ForwardingType_t type);

extern int bcmx_field_qualify_IpType(
    bcm_field_entry_t entry, 
    bcm_field_IpType_t type);

extern int bcmx_field_qualify_L2Format(
    bcm_field_entry_t entry, 
    bcm_field_L2Format_t type);

extern int bcmx_field_qualify_VlanFormat(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_MHOpcode(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_UserDefined(
    bcm_field_entry_t entry, 
    bcm_field_udf_t udf_id, 
    uint8 *data, 
    uint8 *mask);

extern int bcmx_field_qualify_Decap(
    bcm_field_entry_t entry, 
    bcm_field_decap_t decap);

extern int bcmx_field_qualify_HiGig(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

/* Qualify on HiGig destination packets. */
extern int bcmx_field_qualify_DstHiGig(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_Stage(
    bcm_field_entry_t entry, 
    bcm_field_stage_t stage);

extern int bcmx_field_qualify_InterfaceClassPort(
    bcm_field_entry_t entry, 
    uint32 data, 
    uint32 mask);

extern int bcmx_field_qualify_InterfaceClassL2(
    bcm_field_entry_t entry, 
    uint32 data, 
    uint32 mask);

extern int bcmx_field_qualify_InterfaceClassL3(
    bcm_field_entry_t entry, 
    uint32 data, 
    uint32 mask);

extern int bcmx_field_qualify_SrcClassL2(
    bcm_field_entry_t entry, 
    uint32 data, 
    uint32 mask);

extern int bcmx_field_qualify_SrcClassL3(
    bcm_field_entry_t entry, 
    uint32 data, 
    uint32 mask);

extern int bcmx_field_qualify_SrcClassField(
    bcm_field_entry_t entry, 
    uint32 data, 
    uint32 mask);

extern int bcmx_field_qualify_DstClassL2(
    bcm_field_entry_t entry, 
    uint32 data, 
    uint32 mask);

extern int bcmx_field_qualify_DstClassL3(
    bcm_field_entry_t entry, 
    uint32 data, 
    uint32 mask);

extern int bcmx_field_qualify_DstClassField(
    bcm_field_entry_t entry, 
    uint32 data, 
    uint32 mask);

extern int bcmx_field_qualify_L3IntfGroup(
    bcm_field_entry_t entry, 
    bcm_if_group_t data, 
    bcm_if_group_t mask);

extern int bcmx_field_qualify_IpProtocolCommon(
    bcm_field_entry_t entry, 
    bcm_field_IpProtocolCommon_t protocol);

extern int bcmx_field_qualify_InnerIpProtocolCommon(
    bcm_field_entry_t entry, 
    bcm_field_IpProtocolCommon_t protocol);

extern int bcmx_field_qualify_Snap(
    bcm_field_entry_t entry, 
    bcm_field_snap_header_t data, 
    bcm_field_snap_header_t mask);

extern int bcmx_field_qualify_Llc(
    bcm_field_entry_t entry, 
    bcm_field_llc_header_t data, 
    bcm_field_llc_header_t mask);

extern int bcmx_field_qualify_InnerTpid(
    bcm_field_entry_t entry, 
    uint16 tpid);

extern int bcmx_field_qualify_OuterTpid(
    bcm_field_entry_t entry, 
    uint16 tpid);

extern int bcmx_field_qualify_PortClass(
    bcm_field_entry_t entry, 
    uint32 data, 
    uint32 mask);

extern int bcmx_field_qualify_L3Routable(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_IpFrag(
    bcm_field_entry_t entry, 
    bcm_field_IpFrag_t frag_info);

extern int bcmx_field_qualify_LookupClass0(
    bcm_field_entry_t entry, 
    uint32 data, 
    uint32 mask);

extern int bcmx_field_qualify_Vrf(
    bcm_field_entry_t entry, 
    uint32 data, 
    uint32 mask);

extern int bcmx_field_qualify_L3Ingress(
    bcm_field_entry_t entry, 
    uint32 data, 
    uint32 mask);

extern int bcmx_field_qualify_ExtensionHeaderType(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_ExtensionHeaderSubCode(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_ExtensionHeader2Type(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_L4Ports(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_MirrorCopy(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_TunnelTerminated(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_MplsTerminated(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_InnerSrcIp(
    bcm_field_entry_t entry, 
    bcm_ip_t data, 
    bcm_ip_t mask);

extern int bcmx_field_qualify_InnerDstIp(
    bcm_field_entry_t entry, 
    bcm_ip_t data, 
    bcm_ip_t mask);

extern int bcmx_field_qualify_InnerSrcIp6(
    bcm_field_entry_t entry, 
    bcm_ip6_t data, 
    bcm_ip6_t mask);

extern int bcmx_field_qualify_InnerDstIp6(
    bcm_field_entry_t entry, 
    bcm_ip6_t data, 
    bcm_ip6_t mask);

extern int bcmx_field_qualify_InnerSrcIp6High(
    bcm_field_entry_t entry, 
    bcm_ip6_t data, 
    bcm_ip6_t mask);

extern int bcmx_field_qualify_InnerDstIp6High(
    bcm_field_entry_t entry, 
    bcm_ip6_t data, 
    bcm_ip6_t mask);

extern int bcmx_field_qualify_InnerTtl(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_InnerTos(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_InnerDSCP(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_InnerIpProtocol(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_InnerIpFrag(
    bcm_field_entry_t entry, 
    bcm_field_IpFrag_t frag_info);

extern int bcmx_field_qualify_DosAttack(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_IpmcStarGroupHit(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_MyStationHit(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_L2PayloadFirstEightBytes(
    bcm_field_entry_t entry, 
    uint32 data1, 
    uint32 data2, 
    uint32 mask1, 
    uint32 mask2);

extern int bcmx_field_qualify_L3DestRouteHit(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_L3DestHostHit(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_L3SrcHostHit(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_L2CacheHit(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_L2StationMove(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_L2DestHit(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_L2SrcStatic(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_L2SrcHit(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_IngressStpState(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_ForwardingVlanValid(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_SrcVirtualPortValid(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_VlanTranslationHit(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_TranslatedVlanFormat(
    bcm_field_entry_t entry, 
    uint8 data, 
    uint8 mask);

extern int bcmx_field_qualify_FibreChanOuter(
    bcm_field_entry_t entry, 
    bcm_field_FibreChan_t fibre_chan_type);

extern int bcmx_field_qualify_FibreChanInner(
    bcm_field_entry_t entry, 
    bcm_field_FibreChan_t fibre_chan_type);

extern int bcmx_field_qualify_VnTag(
    bcm_field_entry_t entry, 
    uint32 data, 
    uint32 mask);

extern int bcmx_field_qualify_CnTag(
    bcm_field_entry_t entry, 
    uint32 data, 
    uint32 mask);

extern int bcmx_field_qualify_FabricQueueTag(
    bcm_field_entry_t entry, 
    uint32 data, 
    uint32 mask);

extern int bcmx_field_qualify_DstMultipath(
    bcm_field_entry_t entry, 
    bcm_if_t mpintf);

extern int bcmx_field_qualify_IntPriority_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

extern int bcmx_field_qualify_Color_get(
    bcm_field_entry_t entry, 
    uint8 *color);

extern int bcmx_field_qualify_SrcModPortGport_get(
    bcm_field_entry_t entry, 
    bcm_gport_t *data);

extern int bcmx_field_qualify_SrcModuleGport_get(
    bcm_field_entry_t entry, 
    bcm_gport_t *data);

extern int bcmx_field_qualify_LoopbackType_get(
    bcm_field_entry_t entry, 
    bcm_field_LoopbackType_t *loopback_type);

extern int bcmx_field_qualify_TunnelType_get(
    bcm_field_entry_t entry, 
    bcm_field_TunnelType_t *tunnel_type);

extern int bcmx_field_qualify_DstL3Egress_get(
    bcm_field_entry_t entry, 
    bcm_if_t *if_id);

extern int bcmx_field_qualify_DstMulticastGroup_get(
    bcm_field_entry_t entry, 
    bcm_gport_t *group);

extern int bcmx_field_qualify_SrcMplsGport_get(
    bcm_field_entry_t entry, 
    bcm_gport_t *mpls_port_id);

extern int bcmx_field_qualify_DstMplsGport_get(
    bcm_field_entry_t entry, 
    bcm_gport_t *mpls_port_id);

extern int bcmx_field_qualify_SrcMimGport_get(
    bcm_field_entry_t entry, 
    bcm_gport_t *mim_port_id);

extern int bcmx_field_qualify_DstMimGport_get(
    bcm_field_entry_t entry, 
    bcm_gport_t *mim_port_id);

extern int bcmx_field_qualify_SrcWlanGport_get(
    bcm_field_entry_t entry, 
    bcm_gport_t *wlan_port_id);

extern int bcmx_field_qualify_DstWlanGport_get(
    bcm_field_entry_t entry, 
    bcm_gport_t *wlan_port_id);

extern int bcmx_field_qualify_Loopback_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

extern int bcmx_field_qualify_InPort_get(
    bcm_field_entry_t entry, 
    bcm_port_t *data, 
    bcm_port_t *mask);

extern int bcmx_field_qualify_OutPort_get(
    bcm_field_entry_t entry, 
    bcm_port_t *data, 
    bcm_port_t *mask);

extern int bcmx_field_qualify_InPorts_get(
    bcm_field_entry_t entry, 
    bcm_pbmp_t *data, 
    bcm_pbmp_t *mask);

extern int bcmx_field_qualify_OutPorts_get(
    bcm_field_entry_t entry, 
    bcm_pbmp_t *data, 
    bcm_pbmp_t *mask);

extern int bcmx_field_qualify_Drop_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

extern int bcmx_field_qualify_SrcModid_get(
    bcm_field_entry_t entry, 
    bcm_module_t *data, 
    bcm_module_t *mask);

extern int bcmx_field_qualify_SrcPortTgid_get(
    bcm_field_entry_t entry, 
    bcm_port_t *data, 
    bcm_port_t *mask);

extern int bcmx_field_qualify_SrcPort_get(
    bcm_field_entry_t entry, 
    bcm_module_t *data_modid, 
    bcm_module_t *mask_modid, 
    bcm_port_t *data_port, 
    bcm_port_t *mask_port);

extern int bcmx_field_qualify_SrcTrunk_get(
    bcm_field_entry_t entry, 
    bcm_trunk_t *data, 
    bcm_trunk_t *mask);

extern int bcmx_field_qualify_DstModid_get(
    bcm_field_entry_t entry, 
    bcm_module_t *data, 
    bcm_module_t *mask);

extern int bcmx_field_qualify_DstPortTgid_get(
    bcm_field_entry_t entry, 
    bcm_port_t *data, 
    bcm_port_t *mask);

extern int bcmx_field_qualify_DstPort_get(
    bcm_field_entry_t entry, 
    bcm_module_t *data_modid, 
    bcm_module_t *mask_modid, 
    bcm_port_t *data_port, 
    bcm_port_t *mask_port);

extern int bcmx_field_qualify_DstTrunk_get(
    bcm_field_entry_t entry, 
    bcm_trunk_t *data, 
    bcm_trunk_t *mask);

extern int bcmx_field_qualify_InnerL4SrcPort_get(
    bcm_field_entry_t entry, 
    bcm_l4_port_t *data, 
    bcm_l4_port_t *mask);

extern int bcmx_field_qualify_InnerL4DstPort_get(
    bcm_field_entry_t entry, 
    bcm_l4_port_t *data, 
    bcm_l4_port_t *mask);

extern int bcmx_field_qualify_L4SrcPort_get(
    bcm_field_entry_t entry, 
    bcm_l4_port_t *data, 
    bcm_l4_port_t *mask);

extern int bcmx_field_qualify_L4DstPort_get(
    bcm_field_entry_t entry, 
    bcm_l4_port_t *data, 
    bcm_l4_port_t *mask);

extern int bcmx_field_qualify_OuterVlan_get(
    bcm_field_entry_t entry, 
    bcm_vlan_t *data, 
    bcm_vlan_t *mask);

extern int bcmx_field_qualify_OuterVlanId_get(
    bcm_field_entry_t entry, 
    bcm_vlan_t *data, 
    bcm_vlan_t *mask);

/* 
 *  Get match criteria for bcmFieldQualifyOuterVlanPri
 *                  qualifier from the field entry.
 */
extern int bcmx_field_qualify_OuterVlanPri_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 *  Get match criteria for bcmFieldQualifyOuterVlanCfi_get
 *                  qualifier from the field entry.
 */
extern int bcmx_field_qualify_OuterVlanCfi_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyInnerVlan
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_InnerVlan_get(
    bcm_field_entry_t entry, 
    bcm_vlan_t *data, 
    bcm_vlan_t *mask);

/* 
 *  Get match criteria for bcmFieldQualifyInnerVlanId
 *                  qualifier from the field entry.
 */
extern int bcmx_field_qualify_InnerVlanId_get(
    bcm_field_entry_t entry, 
    bcm_vlan_t *data, 
    bcm_vlan_t *mask);

/* 
 *  Get match criteria for bcmFieldQualifyInnerVlanPri
 *                  qualifier from the field entry.
 */
extern int bcmx_field_qualify_InnerVlanPri_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 *  Get match criteria for bcmFieldQualifyInnerVlanCfi_get
 *                  qualifier from the field entry.
 */
extern int bcmx_field_qualify_InnerVlanCfi_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyEtherType
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_EtherType_get(
    bcm_field_entry_t entry, 
    uint16 *data, 
    uint16 *mask);

/* 
 * Get match criteria for bcmFieldQualifyEqualL4Port
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_EqualL4Port_get(
    bcm_field_entry_t entry, 
    uint32 *flag);

/* 
 * Get match criteria for bcmFieldQualifyIpProtocol
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_IpProtocol_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyIpInfo
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_IpInfo_get(
    bcm_field_entry_t entry, 
    uint32 *data, 
    uint32 *mask);

/* 
 * Get match criteria for bcmFieldQualifyPacketRes
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_PacketRes_get(
    bcm_field_entry_t entry, 
    uint32 *data, 
    uint32 *mask);

/* 
 * Get match criteria for bcmFieldQualifySrcIp
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_SrcIp_get(
    bcm_field_entry_t entry, 
    bcm_ip_t *data, 
    bcm_ip_t *mask);

/* 
 * Get match criteria for bcmFieldQualifyDstIp
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_DstIp_get(
    bcm_field_entry_t entry, 
    bcm_ip_t *data, 
    bcm_ip_t *mask);

/* 
 * Get match criteria for bcmFieldQualifyDSCP
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_DSCP_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

extern int bcmx_field_qualify_Tos_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyIpFlags
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_IpFlags_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyTcpControl
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_TcpControl_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyTcpSequenceZero
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_TcpSequenceZero_get(
    bcm_field_entry_t entry, 
    uint32 *flag);

/* 
 * Get match criteria for bcmFieldQualifyTcpHeaderSize
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_TcpHeaderSize_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyTtl
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_Ttl_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyRangeCheck
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_RangeCheck_get(
    bcm_field_entry_t entry, 
    int max_count, 
    bcm_field_range_t *range, 
    int *invert, 
    int *count);

/* 
 * Get match criteria for bcmFieldQualifySrcIp6
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_SrcIp6_get(
    bcm_field_entry_t entry, 
    bcm_ip6_t *data, 
    bcm_ip6_t *mask);

/* 
 * Get match criteria for bcmFieldQualifyDstIp6
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_DstIp6_get(
    bcm_field_entry_t entry, 
    bcm_ip6_t *data, 
    bcm_ip6_t *mask);

/* 
 * Get match criteria for bcmFieldQualifySrcIp6High
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_SrcIp6High_get(
    bcm_field_entry_t entry, 
    bcm_ip6_t *data, 
    bcm_ip6_t *mask);

/* 
 * Get match criteria for bcmFieldQualifySrcIpEqualDstIp
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_SrcIpEqualDstIp_get(
    bcm_field_entry_t entry, 
    uint32 *flag);

/* 
 * Get match criteria for bcmFieldQualifyDstIp6High
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_DstIp6High_get(
    bcm_field_entry_t entry, 
    bcm_ip6_t *data, 
    bcm_ip6_t *mask);

/* 
 * Get match criteria for bcmFieldQualifyDstIp6Low
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_DstIp6Low_get(
    bcm_field_entry_t entry, 
    bcm_ip6_t *data, 
    bcm_ip6_t *mask);

/* 
 * Get match criteria for bcmFieldQualifySrcIp6Low
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_SrcIp6Low_get(
    bcm_field_entry_t entry, 
    bcm_ip6_t *data, 
    bcm_ip6_t *mask);

/* 
 * Get match criteria for bcmFieldQualifyIp6NextHeader
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_Ip6NextHeader_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyIp6TrafficClass
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_Ip6TrafficClass_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyInnerIp6FlowLabel
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_InnerIp6FlowLabel_get(
    bcm_field_entry_t entry, 
    uint32 *data, 
    uint32 *mask);

/* 
 * Get match criteria for bcmFieldQualifyIp6FlowLabel
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_Ip6FlowLabel_get(
    bcm_field_entry_t entry, 
    uint32 *data, 
    uint32 *mask);

/* 
 * Get match criteria for bcmFieldQualifyIp6HopLimit
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_Ip6HopLimit_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifySrcMac
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_SrcMac_get(
    bcm_field_entry_t entry, 
    bcm_mac_t *data, 
    bcm_mac_t *mask);

/* 
 * Get match criteria for bcmFieldQualifyDstMac
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_DstMac_get(
    bcm_field_entry_t entry, 
    bcm_mac_t *data, 
    bcm_mac_t *mask);

/* 
 * Get match criteria for bcmFieldQualifyPacketFormat
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_PacketFormat_get(
    bcm_field_entry_t entry, 
    uint32 *data, 
    uint32 *mask);

/* 
 * Get match criteria for bcmFieldQualifySrcMacGroup
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_SrcMacGroup_get(
    bcm_field_entry_t entry, 
    uint32 *data, 
    uint32 *mask);

/* 
 * Get match criteria for bcmFieldQualifyInnerIpType
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_InnerIpType_get(
    bcm_field_entry_t entry, 
    bcm_field_IpType_t *type);

/* 
 * Get match criteria for bcmFieldQualifyForwardingType
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_ForwardingType_get(
    bcm_field_entry_t entry, 
    bcm_field_ForwardingType_t *type);

/* 
 * Get match criteria for bcmFieldQualifyIpType
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_IpType_get(
    bcm_field_entry_t entry, 
    bcm_field_IpType_t *type);

/* 
 * Get match criteria for bcmFieldQualifyL2Format
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_L2Format_get(
    bcm_field_entry_t entry, 
    bcm_field_L2Format_t *type);

/* 
 * Get match criteria for bcmFieldQualifyTranslatedVlanFormat
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_TranslatedVlanFormat_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyVlanFormat
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_VlanFormat_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyMHOpcode
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_MHOpcode_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyUserDefined
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_UserDefined_get(
    bcm_field_entry_t entry, 
    bcm_field_udf_t udf_id, 
    uint8 data[BCM_FIELD_USER_FIELD_SIZE], 
    uint8 mask[BCM_FIELD_USER_FIELD_SIZE]);

/* 
 * Get match criteria for bcmFieldQualifyDstHiGig
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_DstHiGig_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyHiGig
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_HiGig_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyInterfaceClassPort
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_InterfaceClassPort_get(
    bcm_field_entry_t entry, 
    uint32 *data, 
    uint32 *mask);

/* 
 * Get match criteria for bcmFieldQualifyInterfaceClassL2
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_InterfaceClassL2_get(
    bcm_field_entry_t entry, 
    uint32 *data, 
    uint32 *mask);

/* 
 * Get match criteria for bcmFieldQualifyInterfaceClassL3
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_InterfaceClassL3_get(
    bcm_field_entry_t entry, 
    uint32 *data, 
    uint32 *mask);

/* 
 * Get match criteria for bcmFieldQualifySrcClassL2
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_SrcClassL2_get(
    bcm_field_entry_t entry, 
    uint32 *data, 
    uint32 *mask);

/* 
 * Get match criteria for bcmFieldQualifySrcClassL3
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_SrcClassL3_get(
    bcm_field_entry_t entry, 
    uint32 *data, 
    uint32 *mask);

/* 
 * Get match criteria for bcmFieldQualifySrcClassField
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_SrcClassField_get(
    bcm_field_entry_t entry, 
    uint32 *data, 
    uint32 *mask);

/* 
 * Get match criteria for bcmFieldQualifyDstClassL2
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_DstClassL2_get(
    bcm_field_entry_t entry, 
    uint32 *data, 
    uint32 *mask);

/* 
 * Get match criteria for bcmFieldQualifyDstClassL3
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_DstClassL3_get(
    bcm_field_entry_t entry, 
    uint32 *data, 
    uint32 *mask);

/* 
 * Get match criteria for bcmFieldQualifyDstClassField
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_DstClassField_get(
    bcm_field_entry_t entry, 
    uint32 *data, 
    uint32 *mask);

/* 
 * Get match criteria for bcmFieldQualifyL3IntfGroup
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_L3IntfGroup_get(
    bcm_field_entry_t entry, 
    bcm_if_group_t *data, 
    bcm_if_group_t *mask);

/* 
 * Get match criteria for bcmFieldQualifyIpProtocolCommon
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_IpProtocolCommon_get(
    bcm_field_entry_t entry, 
    bcm_field_IpProtocolCommon_t *protocol);

/* 
 * Get match criteria for bcmFieldQualifyInnerIpProtocolCommon
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_InnerIpProtocolCommon_get(
    bcm_field_entry_t entry, 
    bcm_field_IpProtocolCommon_t *protocol);

/* 
 * Get match criteria for bcmFieldQualifySnap
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_Snap_get(
    bcm_field_entry_t entry, 
    bcm_field_snap_header_t *data, 
    bcm_field_snap_header_t *mask);

/* 
 * Get match criteria for bcmFieldQualifyLlc
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_Llc_get(
    bcm_field_entry_t entry, 
    bcm_field_llc_header_t *data, 
    bcm_field_llc_header_t *mask);

/* 
 * Get match criteria for bcmFieldQualifyInnerTpid
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_InnerTpid_get(
    bcm_field_entry_t entry, 
    uint16 *tpid);

/* 
 * Get match criteria for bcmFieldQualifyOuterTpid
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_OuterTpid_get(
    bcm_field_entry_t entry, 
    uint16 *tpid);

/* 
 * Get match criteria for bcmFieldQualifyPortClass
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_PortClass_get(
    bcm_field_entry_t entry, 
    uint32 *data, 
    uint32 *mask);

/* 
 * Get match criteria for bcmFieldQualifyL3Routable
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_L3Routable_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyIpFrag
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_IpFrag_get(
    bcm_field_entry_t entry, 
    bcm_field_IpFrag_t *frag_info);

/* 
 * Get match criteria for bcmFieldQualifyLookupClass0
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_LookupClass0_get(
    bcm_field_entry_t entry, 
    uint32 *data, 
    uint32 *mask);

/* 
 * Get match criteria for bcmFieldQualifyVrf
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_Vrf_get(
    bcm_field_entry_t entry, 
    uint32 *data, 
    uint32 *mask);

/* 
 * Get match criteria for bcmFieldQualifyL3Ingress
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_L3Ingress_get(
    bcm_field_entry_t entry, 
    uint32 *data, 
    uint32 *mask);

/* 
 * Get match criteria for bcmFieldQualifyExtensionHeaderType
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_ExtensionHeaderType_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyExtensionHeaderSubCode
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_ExtensionHeaderSubCode_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

extern int bcmx_field_qualify_ExtensionHeader2Type_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyL4Ports
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_L4Ports_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyMirrorCopy
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_MirrorCopy_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyTunnelTerminated
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_TunnelTerminated_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyMplsTerminated
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_MplsTerminated_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyInnerSrcIp
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_InnerSrcIp_get(
    bcm_field_entry_t entry, 
    bcm_ip_t *data, 
    bcm_ip_t *mask);

/* 
 * Get match criteria for bcmFieldQualifyInnerDstIp
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_InnerDstIp_get(
    bcm_field_entry_t entry, 
    bcm_ip_t *data, 
    bcm_ip_t *mask);

/* 
 * Get match criteria for bcmFieldQualifyInnerSrcIp6
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_InnerSrcIp6_get(
    bcm_field_entry_t entry, 
    bcm_ip6_t *data, 
    bcm_ip6_t *mask);

/* 
 * Get match criteria for bcmFieldQualifyInnerDstIp6
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_InnerDstIp6_get(
    bcm_field_entry_t entry, 
    bcm_ip6_t *data, 
    bcm_ip6_t *mask);

/* 
 * Get match criteria for bcmFieldQualifyInnerSrcIp6High
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_InnerSrcIp6High_get(
    bcm_field_entry_t entry, 
    bcm_ip6_t *data, 
    bcm_ip6_t *mask);

/* 
 * Get match criteria for bcmFieldQualifyInnerDstIp6High
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_InnerDstIp6High_get(
    bcm_field_entry_t entry, 
    bcm_ip6_t *data, 
    bcm_ip6_t *mask);

/* 
 * Get match criteria for bcmFieldQualifyInnerTtl
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_InnerTtl_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

extern int bcmx_field_qualify_InnerTos_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyInnerDSCP
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_InnerDSCP_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyInnerIpProtocol
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_InnerIpProtocol_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyInnerIpFrag
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_InnerIpFrag_get(
    bcm_field_entry_t entry, 
    bcm_field_IpFrag_t *frag_info);

/* 
 * Get match criteria for bcmFieldQualifyDosAttack
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_DosAttack_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyIpmcStarGroupHit
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_IpmcStarGroupHit_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyMyStationHit
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_MyStationHit_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyL2PayloadFirstEightBytes
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_L2PayloadFirstEightBytes_get(
    bcm_field_entry_t entry, 
    uint32 *data1, 
    uint32 *data2, 
    uint32 *mask1, 
    uint32 *mask2);

/* 
 * Get match criteria for bcmFieldQualifyL3DestRouteHit
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_L3DestRouteHit_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyL3DestHostHit
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_L3DestHostHit_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyL3SrcHostHit
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_L3SrcHostHit_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyL2CacheHit
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_L2CacheHit_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyL2StationMove
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_L2StationMove_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyL2DestHit
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_L2DestHit_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyL2SrcStatic
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_L2SrcStatic_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyL2SrcHit
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_L2SrcHit_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyIngressStpState
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_IngressStpState_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyForwardingVlanValid
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_ForwardingVlanValid_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifySrcVirtualPortValid
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_SrcVirtualPortValid_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyVlanTranslationHit
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_VlanTranslationHit_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyIpAuth
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_IpAuth_get(
    bcm_field_entry_t entry, 
    uint8 *data, 
    uint8 *mask);

/* 
 * Get match criteria for bcmFieldQualifyBigIcmpCheck
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_BigIcmpCheck_get(
    bcm_field_entry_t entry, 
    uint32 *flag, 
    uint32 *size);

/* 
 * Get match criteria for bcmFieldQualifyIcmpTypeCode
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_IcmpTypeCode_get(
    bcm_field_entry_t entry, 
    uint16 *data, 
    uint16 *mask);

/* 
 * Get match criteria for bcmFieldQualifyIgmpTypeMaxRespTime
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_IgmpTypeMaxRespTime_get(
    bcm_field_entry_t entry, 
    uint16 *data, 
    uint16 *mask);

/* 
 * Get Fibre Channel outer header type field qualification from a field
 * entry.
 */
extern int bcmx_field_qualify_FibreChanOuter_get(
    bcm_field_entry_t entry, 
    bcm_field_FibreChan_t *fibre_chan_type);

/* 
 * Get Fibre Channel inner header type field qualification from a field
 * entry.
 */
extern int bcmx_field_qualify_FibreChanInner_get(
    bcm_field_entry_t entry, 
    bcm_field_FibreChan_t *fibre_chan_type);

/* 
 * Get match criteria for bcmFieldQualifyVnTag
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_VnTag_get(
    bcm_field_entry_t entry, 
    uint32 *data, 
    uint32 *mask);

/* 
 * Get match criteria for bcmFieldQualifyCnTag
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_CnTag_get(
    bcm_field_entry_t entry, 
    uint32 *data, 
    uint32 *mask);

/* 
 * Get match criteria for bcmFieldQualifyFabricQueueTag
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_FabricQueueTag_get(
    bcm_field_entry_t entry, 
    uint32 *data, 
    uint32 *mask);

/* 
 * Get match criteria for bcmFieldQualifyDstMultipath
 *                qualifier from the field entry.
 */
extern int bcmx_field_qualify_DstMultipath_get(
    bcm_field_entry_t entry, 
    bcm_if_t *mpintf);

/* Add an action to a field entry. */
extern int bcmx_field_action_add(
    bcm_field_entry_t entry, 
    bcm_field_action_t action, 
    uint32 param0, 
    uint32 param1);

/* Delete an action from a field entry. */
extern int bcmx_field_action_delete(
    bcm_field_entry_t entry, 
    bcm_field_action_t action, 
    uint32 param0, 
    uint32 param1);

/* Add an action to a field entry. */
extern int bcmx_field_action_mac_add(
    bcm_field_entry_t entry, 
    bcm_field_action_t action, 
    bcm_mac_t mac);

/* Add an action to a field entry. */
extern int bcmx_field_action_ports_add(
    bcm_field_entry_t entry, 
    bcm_field_action_t action, 
    bcmx_lplist_t lplist);

/* 
 * Retrieve the parameters for an action previously added to a field
 * entry.
 */
extern int bcmx_field_action_get(
    bcm_field_entry_t entry, 
    bcm_field_action_t action, 
    uint32 *param0, 
    uint32 *param1);

/* 
 * Retrieve the parameters for an action previously added to a field
 * entry.
 */
extern int bcmx_field_action_mac_get(
    bcm_field_entry_t entry, 
    bcm_field_action_t action, 
    bcm_mac_t *mac);

/* 
 * Retrieve the parameters for an action previously added to a field
 * entry.
 */
extern int bcmx_field_action_ports_get(
    bcm_field_entry_t entry, 
    bcm_field_action_t action, 
    bcmx_lplist_t *lplist);

/* Remove an action from a field entry. */
extern int bcmx_field_action_remove(
    bcm_field_entry_t entry, 
    bcm_field_action_t action);

/* Remove all actions from a field entry. */
extern int bcmx_field_action_remove_all(
    bcm_field_entry_t entry);

/* Create stat collection entity. */
extern int bcmx_field_stat_create(
    bcm_field_group_t group, 
    int nstat, 
    bcm_field_stat_t *stat_arr, 
    int *stat_id);

/* Create stat collection entity with given ID. */
extern int bcmx_field_stat_create_id(
    bcm_field_group_t group, 
    int nstat, 
    bcm_field_stat_t *stat_arr, 
    int stat_id);

/* Destroy stat collection entity. */
extern int bcmx_field_stat_destroy(
    int stat_id);

/* 
 * Get number of different statistics associated with stat collection
 * entity.
 */
extern int bcmx_field_stat_size(
    int stat_id, 
    int *stat_size);

/* Get enabled statistics for specific collection entity. */
extern int bcmx_field_stat_config_get(
    int stat_id, 
    int nstat, 
    bcm_field_stat_t *stat_arr);

/* Set 64 bit counter value for specific statistic type. */
extern int bcmx_field_stat_set(
    int stat_id, 
    bcm_field_stat_t stat, 
    uint64 value);

/* Set lower 32 bit counter value for specific statistic type. */
extern int bcmx_field_stat_set32(
    int stat_id, 
    bcm_field_stat_t stat, 
    uint32 value);

/* Set 64 bit counter value for all statistics types. */
extern int bcmx_field_stat_all_set(
    int stat_id, 
    uint64 value);

/* Set lower 32 bit counter value for all statistic types. */
extern int bcmx_field_stat_all_set32(
    int stat_id, 
    uint32 value);

/* Get 64 bit counter value for specific statistic type. */
extern int bcmx_field_stat_get(
    int stat_id, 
    bcm_field_stat_t stat, 
    uint64 *value);

/* Get lower 32 bit counter value for specific statistic type. */
extern int bcmx_field_stat_get32(
    int stat_id, 
    bcm_field_stat_t stat, 
    uint32 *value);

/* Get 64 bit counter values for multiple statistic types. */
extern int bcmx_field_stat_multi_get(
    int stat_id, 
    int nstat, 
    bcm_field_stat_t *stat_arr, 
    uint64 *value_arr);

/* Get lower 32 bit counter values for multiple statistic types. */
extern int bcmx_field_stat_multi_get32(
    int stat_id, 
    int nstat, 
    bcm_field_stat_t *stat_arr, 
    uint32 *value_arr);

/* Attach statistics entity to Field Processor entry. */
extern int bcmx_field_entry_stat_attach(
    bcm_field_entry_t entry, 
    int stat_id);

/* Detach statistics entity from Field Processor entry. */
extern int bcmx_field_entry_stat_detach(
    bcm_field_entry_t entry, 
    int stat_id);

/* Get statistics entity attached to Field Processor entry. */
extern int bcmx_field_entry_stat_get(
    bcm_field_entry_t entry, 
    int *stat_id);

/* Create a field counter pair and associate it with a field entry. */
extern int bcmx_field_counter_create(
    bcm_field_entry_t entry);

/* 
 * Share a field counter pair from one field entry with another field
 * entry.
 */
extern int bcmx_field_counter_share(
    bcm_field_entry_t src_entry, 
    bcm_field_entry_t dst_entry);

/* Remove a field counter pair to field entry association. */
extern int bcmx_field_counter_destroy(
    bcm_field_entry_t entry);

/* Set a field counter value. */
extern int bcmx_field_counter_set(
    bcm_field_entry_t entry, 
    int counter_num, 
    uint64 val);

/* Get a field counter value. */
extern int bcmx_field_counter_set32(
    bcm_field_entry_t entry, 
    int counter_num, 
    uint32 val);

/* Set or get a field counter value. */
extern int bcmx_field_counter_get(
    bcm_field_entry_t entry, 
    int counter_num, 
    uint64 *valp);

/* Set or get a field counter value. */
extern int bcmx_field_counter_get32(
    bcm_field_entry_t entry, 
    int counter_num, 
    uint32 *valp);

/* Create a field meter group and associate it with a field entry. */
extern int bcmx_field_meter_create(
    bcm_field_entry_t entry);

/* 
 * Share the field meter group from one field entry with another field
 * entry.
 */
extern int bcmx_field_meter_share(
    bcm_field_entry_t src_entry, 
    bcm_field_entry_t dst_entry);

/* Remove a field meter association with a field entry. */
extern int bcmx_field_meter_destroy(
    bcm_field_entry_t entry);

/* Set or get the rate parameters for a field meter. */
extern int bcmx_field_meter_set(
    bcm_field_entry_t entry, 
    int meter_num, 
    uint32 kbits_sec, 
    uint32 kbits_burst);

/* Set or get the rate parameters for a field meter. */
extern int bcmx_field_meter_get(
    bcm_field_entry_t entry, 
    int meter_num, 
    uint32 *kbits_sec, 
    uint32 *kbits_burst);

/* SDK 5.2.0 backward compatibility. */
#define bcmx_field_qualify_OutVlan  bcmx_field_qualify_OuterVlan 
#define bcmx_field_qualify_InVlan   bcmx_field_qualify_InnerVlan 

#endif /* __BCMX_FIELD_H__ */
